using System;
using System.Collections.Generic;


namespace Gfw.Models.Site
{
	[Serializable]
	public partial class FctAnnouncement: IEquatable<FctAnnouncement>
	{

		#region Private Members

		private string _id; 
		private DateTime _announcementdate; 
		private string _announcementpublisher; 
		private string _announcementtitle; 
		private string _announcementkeyword; 
		private string _announcementcontent; 
		private int _isshow; 		
		#endregion

		#region Constructor

		public FctAnnouncement()
		{
			_id = String.Empty; 
			_announcementdate = DateTime.MinValue; 
			_announcementpublisher = String.Empty; 
			_announcementtitle = String.Empty; 
			_announcementkeyword = String.Empty;
            _announcementcontent = String.Empty; 
			_isshow = 0; 
		}
		#endregion // End of Default ( Empty ) Class Constuctor

		#region Public Properties
			
		public virtual string Id
		{
			get
			{ 
				return _id;
			}

			set	
			{	
				if( value == null )
					throw new ArgumentOutOfRangeException("Null value not allowed for Id", value, "null");
				
				if(  value.Length > 36)
					throw new ArgumentOutOfRangeException("Invalid value for Id", value, value.ToString());
				
				_id = value;
			}
		}
			
		public virtual DateTime AnnouncementDate
		{
			get
			{ 
				return _announcementdate;
			}
			set
			{
				_announcementdate = value;
			}

		}
			
		public virtual string AnnouncementPublisher
		{
			get
			{ 
				return _announcementpublisher;
			}

			set	
			{	
				if(  value != null &&  value.Length > 50)
					throw new ArgumentOutOfRangeException("Invalid value for AnnouncementPublisher", value, value.ToString());
				
				_announcementpublisher = value;
			}
		}
			
		public virtual string AnnouncementTitle
		{
			get
			{ 
				return _announcementtitle;
			}

			set	
			{	
				if(  value != null &&  value.Length > 50)
					throw new ArgumentOutOfRangeException("Invalid value for AnnouncementTitle", value, value.ToString());
				
				_announcementtitle = value;
			}
		}
			
		public virtual string AnnouncementKeyWord
		{
			get
			{ 
				return _announcementkeyword;
			}

			set	
			{	
				if(  value != null &&  value.Length > 50)
					throw new ArgumentOutOfRangeException("Invalid value for AnnouncementKeyWord", value, value.ToString());
				
				_announcementkeyword = value;
			}
		}
			
		public virtual string AnnouncementContent
		{
			get
			{ 
				return _announcementcontent;
			}
			set
			{
				_announcementcontent = value;
			}

		}
			
		public virtual int IsShow
		{
			get
			{ 
				return _isshow;
			}
			set
			{
				_isshow = value;
			}

		}
			
				
		#endregion 

		#region Public Functions

		#endregion //Public Functions

		#region IEquatable members

		public virtual bool Equals(FctAnnouncement other)
		{
			if (other == this)
				return true;
		
			return ( other != null ) &&
				( this._id == other.Id );
				   
		}

		#endregion
		
	}
}
